package com.george.shiro;

import com.george.shiro.util.IdWorker;
import org.mybatis.spring.annotation.MapperScan;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.transaction.annotation.EnableTransactionManagement;

/**
 * <p>
 *
 * </p>
 *
 * @author GeorgeChan 2019/5/21 20:47
 * @version 1.0
 * @since jdk1.8
 */
@SpringBootApplication
@EnableTransactionManagement
@MapperScan("com.george.shiro.*.dao")
public class ShiroApplication {
    protected final static Logger LOGGER = LoggerFactory.getLogger(ShiroApplication.class);
    public static void main(String[] args) {
        SpringApplication.run(ShiroApplication.class, args);
        LOGGER.info("启动成功......");
    }


    @Bean
    public IdWorker idWorkker(){
        return new IdWorker(1, 1);
    }
}
